package com.sinodata.bsm.center.dao;

import java.util.List;

import com.sinodata.bsm.center.bean.Condition;
import com.sinodata.bsm.center.bean.EventRuleBo;
import com.sinodata.bsm.center.bean.Page;
import com.sinodata.bsm.common.vo.DefaultEventRule;

/**
 * <p>
 * Description: 事件规则接口
 * </p>
 *
 * @author dongyushi
 * @version 1.0

 * <p>
 * History: 
 *
 * Date                     Author         Version     Description
 * ---------------------------------------------------------------------------------
 * 2012-6-25 PM 11:24:21    dongyushi        1.0         To create
 * </p>
 *
 * @since 
 * @see     
 */
public interface EventRuleDao {
    /**
     * 分页获取默认事件规则
     * @param page
     * @param condition
     * @return
     */
    public Page<DefaultEventRule> findDefaultEventRuleByPage(Page<DefaultEventRule> page, Condition condition);

    /**
     * 查询某资源的所有事件规则
     * 
     * @param resId
     * @return
     */
    public List<EventRuleBo> findByRes(Long resId);

    /**
     * 根据资源Id删除关联的事件规则
     * @param resId
     */
    public void deleteByResId(Long resId);

}